//DuyAnh :: check file size
$.validator.addMethod('filesize', function(value, element, param) {
	// param = size (en bytes) 
	// element = element to validate (<input>)
	// value = value of the element (file name)
	if(!isIE()){
		return this.optional(element) || (element.files[0].size <= param);
	} 
	return true;
}, 'file size is greater than allowed limit');